Previous Book Contents Book Index Next

Inside Macintosh: Open Transport /
Chapter 16 - Serial Endpoint Providers / Serial Endpoint Providers Reference
Serial-Specific Commands


I_SetFramingType

This command sets the framing type for a serial port. Currently, serial ports can support four different framing types, as enumerated in the fCapabilities field of the OTPortRecord. These are kOTSerialFramingAsync, kOTSerialFramingHDLC, kOTSerialFramingSDLC, and kOTSerialFramingAsyncPackets. The normal mode of operation is kOTSerialFramingAsync. You can change the mode of operation to the asynchronous packet framing type by making this OTIoctl command:

OTIoctl(theSerialEndpoint, I_OTSetFramingType, kOTSerialFramingAsyncPackets);
If you select the kOTSerialFramingAsyncPackets type, the underlying serial provider assumes that each individual message that arrives is a separate packet, and should be sent as such. It also means that the underlying provider ensures that if data is flushed, all data will be flushed except any packet that is being processed at the time of the flush. This behavior is important to technologies like Apple Remote Access (ARA) or Point-to-Point Protocol (PPP) implementations, which use the serial port for delivery of discrete packets, because


Previous Book Contents Book Index Next

© Apple Computer, Inc.
15 AUG 1996